package com.chendx.store.order.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.chendx.model.common.dtos.ResponseResult;
import com.chendx.model.order.dto.OrderDto;
import com.chendx.model.order.pojo.Order;

/**
 * Created by chendx on 2022/4/19.
 */
public interface OrderService extends IService<Order> {

    /**
     * 购物车结算订单
     * @param dto
     * @return
     */
    ResponseResult addCartOrder(OrderDto dto);

    /**
     * 优惠金额
     * @param prefId
     * @return
     */
    public ResponseResult afterPrePrice(String prefId);

    /**
     * 商品页面结算订单
     * @param dto
     * @return
     */
    ResponseResult addOrder(OrderDto dto);

    /**
     * 订单支付
     * @param dto
     * @return
     */
    ResponseResult pay( OrderDto dto);

    /**
     * 用户所有订单
     * @return
     */
    ResponseResult loadUserAllOrder();

    /**
     * 分页查询订单
     * @param dto
     * @return
     */
    ResponseResult loadOrderPage(OrderDto dto);

    /**
     * 查询单个订单
     * @param orderId
     * @return
     */
    ResponseResult loadOne(String orderId);

    /**
     * 关闭订单
     * @param orderId
     * @return
     */
    ResponseResult closeOrder(String orderId);

    /**
     * 删除订单
     */
    ResponseResult deleteOrder(String orderId);

    /**
     * 取消订单
     * @param orderId
     * @return
     */
    ResponseResult cancelOrder(String orderId);

    /**
     * 确认收货
     * @param id
     * @return
     */
    ResponseResult goods(String id);

    /**
     * 获取用户未读的订单消息提醒
     * @return
     */
    public ResponseResult getNoReadOrderNotice();

    /**
     * 获取用户未读的订单消息列表
     * @return
     */
    public ResponseResult getOrderNotice();

    /**
     * 将未读标记已读
     * @return
     */
    public ResponseResult read();


}
